package com.cao.meet;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;

public class SecondActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_second);

//        passWord = (GridPasswordView) findViewById(R.id.passWord);
//
//        passWord.forceInputViewGetFocus();
//
//        passWord.setPasswordType(PasswordType.NUMBER);
//
//        passWord.setBackgroundResource(R.mipmap.ic_launcher);
//
//        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
//            passWord.setBackground(getDrawable(R.drawable.round));
//        }
//
//        passWord.setOnPasswordChangedListener(new GridPasswordView.OnPasswordChangedListener() {
//            @Override
//            public void onTextChanged(String psw) {
//                Log.e("psw",psw);
//            }
//
//            @Override
//            public void onInputFinish(String psw) {
//                Log.e("psw_psw",psw);
//            }
//        });

        PasswordView pass = (PasswordView) findViewById(R.id.pass);

        pass.setMode(PasswordView.Mode.RECT);

        pass.setPasswordListener(new PasswordView.PasswordListener() {
            @Override
            public void passwordChange(String changeText) {
                Log.e("changeText",changeText);
            }

            @Override
            public void passwordComplete() {

            }

            @Override
            public void keyEnterPress(String password, boolean isComplete) {

            }
        });

    }
}
